import request from '@/utils/request'

// 查询流程评估配置列表
export function listEvaluationSetting(query) {
  return request({
    url: '/system/evaluationSetting/list',
    method: 'get',
    params: query
  })
}

// 查询流程评估配置详细
export function getEvaluationSetting(evaluationId) {
  return request({
    url: '/system/evaluationSetting/' + evaluationId,
    method: 'get'
  })
}

// 新增流程评估配置
export function addEvaluationSetting(data) {
  return request({
    url: '/system/evaluationSetting',
    method: 'post',
    data: data
  })
}

// 修改流程评估配置
export function updateEvaluationSetting(data) {
  return request({
    url: '/system/evaluationSetting',
    method: 'put',
    data: data
  })
}

// 删除流程评估配置
export function delEvaluationSetting(evaluationId) {
  return request({
    url: '/system/evaluationSetting/' + evaluationId,
    method: 'delete'
  })
}

// 查询流程评估列表
export function evaluateInfoList(businessId) {
  return request({
    url: '/system/evaluationSetting/evaluateInfoList/' + businessId,
    method: 'get'
  })
}

export function addOrUpdateEvaluateInfo(data) {
  return request({
    url: '/system/evaluationSetting/addOrUpdateEvaluateInfo',
    method: 'post',
    data: data
  })
}

export function deleteByBusinessId(businessId) {
  return request({
    url: '/system/evaluationSetting/delete/' + businessId,
    method: 'get'
  })
}

